package com.abysscore.yachtdesign;
import java.awt.Color;

public class TFreeSubdivisionControlCurve extends TFreeSubdivisionBase{
	private boolean FVisible;
	private TFasterList FControlPoints;
	private TFasterList FSubdividedPoints;
	private TFreeSpline FCurve;
	private boolean FBuild;


	private Color FGetColor()
	{
		return null;
	}
	private int FGetNumberOfControlPoints()
	{
		return 0;
	}
	private TFreeSubdivisionControlPoint FGetControlPoint(int Index)
	{
		return null;
	}
	private boolean FGetSelected()
	{
		return false;
	}
	private boolean FGetVisible()
	{
		return FVisible;
	}
	private void FSetBuild(boolean Val)
	{
		FBuild = Val;
	}
	private void FSetSelected(boolean val)
	{
		;
	}

	
	public void AddPoint(TFreeSubdivisionPoint P)
	{
		;
	}
	public void Clear()
	{
		;
	}
	public TFreeSubdivisionControlCurve(TFreeSubdivisionSurface Owner)
	{
		super(Owner);
	}
	public void Delete()
	{
		;
	}
	public void DeleteEdge(TFreeSubdivisionControlEdge Edge)
	{
		;
	}
	//public destructor Destroy;                                                     override;
	public int DistanceToCursor(int X,int Y, TFreeViewport Viewport)
	{
		return 0;
	}
	public void Draw(TFreeViewport Viewport)
	{
		;
	}
	public void InsertControlPoint(TFreeSubdivisionControlPoint P1,TFreeSubdivisionControlPoint P2,TFreeSubdivisionControlPoint New)
	{
		;
	}
	public void InsertEdgePoint(TFreeSubdivisionPoint P1,TFreeSubdivisionPoint P2, TFreeSubdivisionPoint New)
	{
		;
	}
	
	public void LoadBinary(TFreeFileBuffer Source)
	{
		int I =0;
		int N =0;
		int Ind=0;
		TFreeSubdivisionPoint P1;
		TFreeSubdivisionPoint P2;
		TFreeSubdivisionEdge Edge;
	    boolean Sel=false;

	    Source.Load(N);
	    FControlPoints.Capacity(N);
	    P1=null;
	    for (I=1; I<=N; I++)
	    {
	    	Source.Load(Ind);
	    	P2= (TFreeSubdivisionPoint) Owner().ControlPoints(Ind);
	    	FControlPoints.Add(P2);
	    	if (I>1)
	    	{
	    		Edge=Owner().EdgeExists(P1,P2);
	    		if (Edge!=null)
	    		{
	    			Edge.FCurve=this;
	    		}
	    	}
	    	P1=P2;
	    }
	    FSubdividedPoints.AddList(FControlPoints);
	    Source.Load(Sel);
	    if (Sel)
	    	Selected(true);
	}
	
	public void ReplaceVertexPoint(TFreeSubdivisionPoint Old,TFreeSubdivisionPoint New)
	{
		;
	}
	public void SaveBinary(TFreeFileBuffer Destination)
	{
		;
	}
	public void SaveToDXF(TStringList Strings)
	{
		;
	}
	
	
	public boolean Build()
	{
		return FBuild;
	}
	public void Build(boolean val)
	{
		FSetBuild(val);
	}

	public Color Color()
	{
		return FGetColor();
	}
	public TFreeSpline Curve()
	{
		return FCurve;
	}
	public int NumberOfControlPoints()
	{
		return FGetNumberOfControlPoints();
	}
	public TFreeSubdivisionControlPoint ControlPoint(int index)
	{
		return FGetControlPoint(index);
	}

	public boolean Selected()
	{
		return FGetSelected();
	}
	public void Selected(boolean val)
	{
		FSetSelected(val);       // Property to see if this edge has been selected by the user
	}
	public boolean Visible()
	{
		return FGetVisible();
	}
	public void Visible(boolean val)
	{
		FVisible = val;
	}
}
